package com.scau402.system1.domain.dto;

import cn.hutool.core.exceptions.ValidateException;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.*;
import java.util.List;

/**
 * 审核动作DTO
 * @since 2024/2/5
 */
@Data
@NoArgsConstructor
public class AuditOrderDTO {
    /**
     * 审核状态：1：通过、2：驳回
     */
    @NotNull(message = "审核类型不能为空!")
    @Pattern(regexp = "^[1-2]$",message = "审核类型错误")
    private String status;
    /**
     * 批量审核的审核单id们
     */
    @NotNull(message = "未选择审核单！")
    @NotEmpty(message = "未选择审核单!")
    private List<Integer> ids;
    /**
     * 备注
     */
    @Length(max = 255,min = 0,message = "备注长度限制为0~255!")
    private String remark;
}
